Skip to content

Conversation

samisalreadytaken
Copy link

When the loop fails its i < 48 condition, it will access out of array bounds on GetWeapon right after. This was mostly benign because CHandle m_hMyWeapons[48] is followed by CHandle m_hActiveWeapon in memory, so m_hMyWeapons[48] would access m_hActiveWeapon, which would always be null because the entity can't have an active weapon with no weapons.


PR Checklist

  • My PR follows all guidelines in the CONTRIBUTING.md file
  • My PR targets a develop branch OR targets another branch with a specific goal in mind

@Blixibon Blixibon merged commit de59834 into mapbase-source:develop Jan 4, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants